package loengud.w15;

public class OperatorsExample {

	public static void main(String[] args) {
		int a = 1;
		
		System.out.println(a); // outputs 1
		a++; // a = a + 1
		System.out.println(a); // outputs 2
		System.out.println(a++); // outputs 2, a = a + 1
		System.out.println(a); // outputs 3
		System.out.println(++a); // a = a + 1, outputs 4

		
		// assignment
		a = 15;
		System.out.println(a *= 2); // a = a * 2, outputs 30
		System.out.println(a /= 3); // a = a / 3, outputs 10
		System.out.println(a); // outputs 10
	}

}
